package com.ccb.ha.zhxf.service.impl;

import com.ccb.ha.zhxf.entity.Mechanism;
import com.ccb.ha.zhxf.entity.User;
import com.ccb.ha.zhxf.mapper.MechanismMapper;
import com.ccb.ha.zhxf.service.MechanismSerivce;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @Author GanYuzhou
 * @Date 2020/5/18 17:57
 * @Version 1.0
 */
@Service("mechanismSerivce")
public class MechanismServiceImpl implements MechanismSerivce {


    @Autowired
    private MechanismMapper mechanismMapper;
    @Override
    public List<Mechanism> findAll() {
        return mechanismMapper.findAll();
    }

    @Override
    public List<Mechanism> findById(int mechanism_id) {
        return mechanismMapper.findById(mechanism_id);
    }

    @Override
    public int insertMechanism(Mechanism mechanisms) {
        return mechanismMapper.insertMechanism(mechanisms);
    }

    @Override
    public int updateMechanism(Mechanism mechanisms) {
        return mechanismMapper.updateMechanism(mechanisms);
    }

    @Override
    public int deleteMechanism(int mechanism_id) {
        return mechanismMapper.deleteMechanism(mechanism_id);
    }
}
